/*                                                                                                   
 _____      _           _            ______             
|  __ \    (_)         | |           | ___ \            
| |  \/_ __ _ _ __   __| | ___ _ __  | |_/ / ___  _   _ 
| | __| '__| | '_ \ / _` |/ _ \ '__| | ___ \/ _ \| | | |
| |_\ \ |  | | | | | (_| |  __/ |    | |_/ / (_) | |_| |
 \____/_|  |_|_| |_|\__,_|\___|_|    \____/ \___/ \__, |
                                                   __/ |
                                                  |___/ 

FILENAME        : Registers.cpp
CREATED         : 2011-05-15
DESCRIPTION     : LR35902 Cpu registers implementation

*/

#ifndef __GUID_AFCD4506_2F46_4AA8_8792_17C48CA5D158__
#define __GUID_AFCD4506_2F46_4AA8_8792_17C48CA5D158__

#include "../../../Types.hpp"

namespace GrinderBoy
{
    namespace Kernel
    {
        namespace CPU
        {
            namespace Sharp
            {
                namespace LR35902
                {
                    ///<documentation language="en-US">
                    ///<summary>
                    /// This non-iheritable class contains interrupt related stuff for cpu.
                    ///</sumary>
                    ///</documentation>
                    class InterruptMask
                    {
                        private:
                            ///<documentation language="en-US">
                            ///<summary>
                            /// Creates new instance of InteruuptMask class. It's private to keep non-inheritable model.
                            ///</sumary>
                            ///</documentation>
                            InterruptMask();
                            ///<documentation language="en-US">
                            ///<summary>
                            /// Destroys the instance. It's pure virtual to prevent inheritance too.
                            ///</sumary>
                            ///</documentation>
                            virtual ~InterruptMask() = 0;
                        public:
                            ///<documentation language="en-US">
                            ///<summary>
                            /// The V-Blank interrupt occurs ~59.7 times a second on a regular GB and ~61.1 times a second on a Super GB (SGB). This interrupt occurs at the beginning of
                            /// the V-Blank period. During this period video hardware is not using video ram so it may be freely accessed. This period lasts approximately 1.1 milliseconds.
                            ///</sumary>
                            ///</documentation>
                            static const GrinderBoy::Kernel::UInt8 VerticalBlankInterrupt = 0x01;
                            ///<documentation language="en-US">
                            ///<summary>
                            /// There are various reasons for this interrupt to occur as described by the STAT register ($FF40). One very popular reason is 
                            /// to indicate to the user when the video hardware is about to redraw a given LCD line. This can be useful for dynamically controlling 
                            /// the SCX/SCY registers ($FF43/$FF42) to perform special video effects.
                            ///</sumary>
                            ///</documentation>
                            static const GrinderBoy::Kernel::UInt8 LCDCInterrupt = 0x02;
                            ///<documentation language="en-US">
                            ///<summary>
                            /// This interrupt occurs when the TIMA register ($FF05) changes from $FF to $00.
                            ///</sumary>
                            ///</documentation>
                            static const GrinderBoy::Kernel::UInt8 TimerOverflowInterrupt = 0x04;
                            ///<documentation language="en-US">
                            ///<summary>
                            /// This interrupt occurs when a serial transfer has completed on the game link port.
                            ///</sumary>
                            ///</documentation>
                            static const GrinderBoy::Kernel::UInt8 SIOTransferCompleteInterrupt = 0x08;
                            ///<documentation language="en-US">
                            ///<summary>
                            /// This interrupt occurs on a transition of any of the keypad input lines from high to low. Due to the fact that keypad "bounce" 
                            /// is virtually always present, software should expect this interrupt to occur one or more times for every button press and one or 
                            /// more times for every button release.
                            ///</sumary>
                            ///</documentation>
                            static const GrinderBoy::Kernel::UInt8 HiLoTransitionInterrupt = 0x10;
                    }
                }
            }
        }
    }
}

#endif // __GUID_AFCD4506_2F46_4AA8_8792_17C48CA5D158__
